Dynomotion

Group: DynoMotion Message: 4029 From: quelisto Date: 2/21/2012
Subject: Servoing still not happening
Tom:

I've tried everything you've said, all reasonable combinations and permutations. There has got to be some missing piece of information I don't have. Last time it was the ch->CommutationOffset that kept Write3PH() from working. One little detail like that is all it takes for a days' effort to become totally futile.

I have uploaded the .c file (to the Easy E folder) that I've been using to horse around with this motor. The goal is to get this to work with the Halls, eventually. Right now, though, I just want the BLDC to work with the servo and the 256 LINE quadrature encoder.

To clarify, what I do towards the end of this program is to execute a Write3PH() to the motor, and hold it there for 3 seconds. I then Zero the axis, and set the commutation offset to 1/4 cycle away. I then enable the axis and try to jog - zero net movement, but the motor has got current and you can tell the servo is struggling mightily as it fights itself. I have "cleared" the filters by assigning all zero coefficients as you can see (I'm not sure what else "clearing" the filters means).

-Erik-

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Yes do what I requested in the last two emails :}
>  
> TK
>
> From: quelisto <quelisto@...>
> To: DynoMotion@yahoogroups.com
> Sent: Tuesday, February 21, 2012 12:37 PM
> Subject: [DynoMotion] Hmmm, a 256 count per rev diff encoder is giving 1024 counts per rev
>
>
>  
> Hi Tom, I think maybe my troubles with the BLDC have something to do with the afforementioned curiousity. I checked the documentation on my encoder, and sure enough, it is a more standard 256 count per rev encoder (not a 512 CPR). I am using the Kanalog Diff 0 input for the interface, using ch#->InputChan0= Encoder0_Channel.
>
> I wrote a little program to watch the position as I turn the shaft by hand, and sure enough, I repeatably get +1024 counts going one way, -1024 going the other.
>
> I have tried a bunch of permutation/combinations for both the inv_Dist adn the commutator offset (1/256, 1/512, 1/128; 32, 64, 128, 256). None work.
>
> So...any advice?
>
Group: DynoMotion Message: 4030 From: Tom Kerekes Date: 2/21/2012
Subject: Re: Servoing still not happening
Hi Erik,
 
I asked for a simple program to move the motor through 10 electrical cycles and check the encoder before and after to determine the number of encoder counts per cycle.  If you did not do this please describe what you did do to verify the value.
 
I intended to use the Screens to do the testing but you are using a program istead.
 
The Clear button on the Filter Screen sets the filters to a DC gain of 1 (B0=1).  You are setting everything to zero so I don't understand how there is any output at all.
 
Use EnableAxis() to enable an axis.
 
You can use Delay_sec(); to delay.
 
Please clean up, simplify, and remove all Hall related items until we get it working.
 
Do not try to Jog.  The first step is to just servo and check the commutation as I described.
 
You should be aware that with a Max Error of 200 and P=.1 then the max output will limited to 20 before the Max Output of 100 is reached. 
 
Regards
TK